<extend name="Public:innerbase" />
<block name="css"></block>
<block name="js">
<include file="Public:upload" />
<script type="text/javascript" src="{:STATICS}/js/holder.min.js"></script>
<script type="text/javascript">
//弹出层start
$(function(){
	$(".but").click(function(){
        var messageid = $(this).attr("messageid");
		//var str = "这里是信息内容，这里是信息内容！";
		$(".form").html(messageid);
		$("#faqbg").css({display:"block",height:$(document).height()});
		var yscroll =document.documentElement.scrollTop;
		$("#faqdiv").css("top","100px");
		$("#faqdiv").css("display","block");
		document.documentElement.scrollTop=0;
	});
	$(".close").click(function(){
		$("#faqbg").css("display","none");
		$("#faqdiv").css("display","none");
	});
})
//弹出层end

//校验提交是否为空
function check(){
   if( document.getElementById("addcontent").value.length < 1){
	   alert("请输入回复内容");
	   return false;
   }
   if($("#name").val()==''){
	   alert("请添加微信名");
	   return false;
   }
}
</script>
</block>
<block name="content">
<div class="container-fluid">
	<div class="page-header wm-page-header">
		<h3>留言回复</h3>
		<a href="{:U('Sun/message',array('id'=>$id))}" class="btn btn-sm btn-default">
			<span class="glyphicon glyphicon-chevron-left"></span>
			返回
		</a>
	</div>
	<form class="form-horizontal" method="post" onsubmit="return check();" >
	<input type="hidden" name="id" value="{$id}" class="form-control" />
    <div class="form-group">
			<label class="col-sm-2 control-label wm-control-label" >微信名称</label>
			<div class="col-md-4">
				<input type="text" name="name" id="name" class="form-control" />
			</div>
		</div>
		<div class="form-group">
			<label for="ppicurl" class="col-sm-2 control-label wm-control-label">留言头像</label>
			<div class="col-sm-6" >
				<input type="hidden" name="ppicurl" id="ppicurl" value="{$vo.ppicurl|default=RES.'/images/photo/noneimg.jpg'}" class="form-control" />
				<img id="ppicurlHolder" style="width:216px;height:120px;" <if condition="($vo eq null) OR($vo['ppicurl'] eq '')">src="{:RES}/images/photo/noneimg.jpg"</if> src="{$vo.ppicurl}"/>
				<div class="btn-group" style="vertical-align:bottom;">
					<span class="btn btn-xs btn-primary" onclick="selectAsset('ppicurl',640,640)">
						<span class="glyphicon glyphicon-cloud-upload"></span>选择
					</span>
					<span class="btn btn-primary btn-xs" onclick="previewImg('ppicurl')">
						<span class="glyphicon glyphicon-picture"></span>预览
					</span>
					&nbsp;&nbsp;建议尺寸:640*640
				</div>
			</div>
		</div>
		
		
		
		
		<div class="form-group">
			<label class="col-sm-2 control-label wm-control-label" >内容</label>
			<div class="col-md-4">
				<textarea  id="addcontent" name="content"  rows="5" class="form-control"></textarea>
			</div>
		</div>

		<div class="form-group">
			<div class="col-md-4">
				<input type="submit" value="提交" class="btn btn-success" />
			</div>
		</div>
	</form>
	<hr/>
		
</block>

<script src="{:RES}/js/date/WdatePicker.js"></script>
<script type="text/javascript" src="{:RES}/js/formCheck/formcheck.js"> </script>

<link rel="stylesheet" type="text/css" href="{:RES}/css/cymain.css" />
<script src="{:STATICS}/jquery.min.js"></script>
<div class="clr"></div>
</div>
</div>
</body>
</html>